#!/usr/bin/python
# -*- coding: utf-8 -*-

#多变量赋值
num, float1, str1 = 10, 0.5, '1'
print(num)
print(type(num))
print(float1)
print(type(float1))
print(str1)
print(type(str1))


#多变量相同赋值
num1 = num2 = 1

print(num1)
print(num2)


#复合赋值运算符
a = 100
a += 1
print(a)


b = 2
b *= 3
print(b)

c = 5
c += 1 + 2
print(c)


#比较运算符
a = 7
b = 5
print(a == b)
print(a != b)
print(a < b)
print(a > b)
print(a <= b)
print(a >= b)

#逻辑运算符
a = 1
b = 2
c = 3
print((a < b) and (b < c))
print((a > b) and (b < c))
print((a > b) or (b < c))
print(not(a > b))

#逻辑运算
a = 0
b = 1
c = 2
print(a and b)
print(b and a)
print(a and c)
print(c and a)
print(b and c)
print(c and b)

print(a or b)
print(a or c)
print(b or c)


